<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
</head>
<body>
<script>
  let user1 = {
    name: "张三",
    key: Symbol()
  }
  let user2 = {
    name: "张三",
    key: Symbol()
  }
  let grade = {
    [user1.key]: {js: 100, java: 99},
    [user2.key]: {js: 22, java: 55}
  }

  console.log(grade[user1.key])
</script>
</body>
</html>